// import { Socket } from "./net/socket/Socket";
import C_MessageCenter from "./utils/C_MessageCenter";
import C_RandomUtils from "./utils/C_RandomUtils";
import { C_TimeManager } from "./utils/C_TimeManager";
// declare global {
//     interface Window {
//         SHOW_LOG: boolean;
//         SHOW_ERROR: boolean;
//         SHOW_ASSERT: boolean;
//         IS_GM: boolean;
//         DEBUG_CODE: boolean;
//         IS_SUB: boolean;
//     }
//     const DEBUG_CODE: boolean;
//     const SHOW_LOG: boolean;
//     const SHOW_ERROR: boolean;
//     const SHOW_ASSERT: boolean;
//     const IS_GM: boolean;
//     const IS_SUB: boolean;
// }
// if (typeof window.SHOW_LOG == 'undefined') {
//     window.IS_GM = true;
//     window.SHOW_LOG = true;
//     window.SHOW_ERROR = true;
//     window.SHOW_ASSERT = true;
//     window.DEBUG_CODE = true;
//     window.IS_SUB = false;
// }
export default class C_App {
    public static isInit: boolean = false;
    // static Socket: Socket;
    public static init() {
        if (this.isInit) {
            return;
        }
        // App.Socket = new Socket();
        this.isInit = true;
        this.ObjectPool = new C_ObjectPool();
        this.NotificationCenter = new C_MessageCenter(1);
        // App.MessageCenter = new MessageCenter(1);
        this.TimerManager = new C_TimeManager();
        this.RandomUtils = new C_RandomUtils();
    }
    public static ObjectPool: C_ObjectPool = null;
    public static TimerManager: C_TimeManager = null;
    public static NotificationCenter: C_MessageCenter = null;
    public static RandomUtils: C_RandomUtils = null;

}
window["C_App"] = C_App;//方便原生端调用